package com.dux.spbtservice.jpa;

import com.dux.spbtservice.domin.Role;
import org.springframework.data.jpa.repository.EntityGraph;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * Title: RoleRepo <br>
 * Description: RoleRepo <br>
 * Date: 2018年10月23日
 *
 * @author 王东旭
 * @version 1.0.0
 * @since jdk8
 */

@Repository
public interface RoleRepo extends JpaRepository<Role,Long> {

    @Override
    @EntityGraph(value = "role.perms",type = EntityGraph.EntityGraphType.LOAD)
    List<Role> findAllById(Iterable<Long> longs);

}
